package top.lingkang.authoritypro.data.entity;

import lombok.Data;
import org.hibernate.annotations.CreationTimestamp;
import org.hibernate.annotations.UpdateTimestamp;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * @author lingkang
 * Created by 2021/12/13
 */
@Entity
@Table(name = "ad_authority")
@org.hibernate.annotations.Table(appliesTo = "ad_authority", comment = "授权表")
@Data
public class Authority implements Serializable {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)//主键递增策略
    private Long id;

    @Column(unique = true)
    private String url;

    private String description;

    @UpdateTimestamp
    private Date updateTime;

    @CreationTimestamp
    private Date createTime;
}
